package com.neuedu.entity;

import com.mybatisflex.annotation.ColumnMask;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;

import com.mybatisflex.core.mask.Masks;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serial;
import java.sql.Date;

/**
 * 就诊人信息表 实体类。
 *
 * @author Administrator
 * @since 2024-06-04
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table("visitor")
public class Visitor implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    public Visitor(String name, Integer type, String idCard, String phone, Integer customerId, Integer sex, Date birthday) {
        this.name = name;
        this.type = type;
        this.idCard = idCard;
        this.phone = phone;
        this.customerId = customerId;
        this.sex = sex;
        this.birthday = birthday;
    }

    @Id(keyType = KeyType.Auto)
    private Integer id;

    /**
     * 姓名
     */
    @ColumnMask(Masks.CHINESE_NAME)
    private String name;

    /**
     * 1 身份证 2 护照 3 外籍居住证
     */
    private Integer type;

    /**
     * 证件号
     */
    @ColumnMask(Masks.ID_CARD_NUMBER)
    private String idCard;

    /**
     * 手机号
     */
    @ColumnMask(Masks.MOBILE)
    private String phone;

    /**
     * 客户id
     * */
    private Integer customerId;

    /**
     * 性别
     * 1 男 0 女
     * */
    private Integer sex;

    /**
     * 生日
     * */
    private Date birthday;
}
